package cn.signalpha.modules.resource.config;

import cn.signalpha.modules.resource.builder.sms.SmsBuilder;
import cn.signalpha.modules.resource.service.ISmsService;
import lombok.AllArgsConstructor;
import cn.signalpha.core.redis.cache.RedisCache;
import cn.signalpha.core.sms.props.SmsProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * Sms配置类
 */
@AllArgsConstructor
@Configuration(proxyBeanMethods = false)
public class SmsConfiguration {

	private final SmsProperties smsProperties;

	private final ISmsService smsService;

	private final RedisCache redisCache;

	@Bean
	public SmsBuilder smsBuilder() {
		return new SmsBuilder(smsProperties, smsService, redisCache);
	}

}
